<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Chart API</title>
<style type="text/css">
#chart-01{
	width:450px;
	height:140px;
	background:url(chart.png) no-repeat;
}
</style>
<script type="text/javascript" src="prototype.js"></script>
<script type="text/javascript" src="googlechartapi.prototype.js"></script>
<script type="text/javascript">
Event.observe(window,'load',autoChart);
function autoChart(){
	
	setInterval(function(){
		var num1 = Math.random()*100;
		var num2 = Math.random()*100;
		var num3 = Math.random()*100;
		var num4 = Math.random()*100;
		var num5 = Math.random()*100;
		var num6 = Math.random()*100;
		var num7 = Math.random()*100;
		var num8 = Math.random()*100;
		var num9 = Math.random()*100;
		var num10 = Math.random()*100;
		var num11 = Math.random()*100;
		var num12 = Math.random()*100;
		var num13 = Math.random()*100;
		var num14 = Math.random()*100;
		var num15 = Math.random()*100;
		var num16 = Math.random()*100;
		var num17 = Math.random()*100;
		var num18 = Math.random()*100;
		var num19 = Math.random()*100;
		var num20 = Math.random()*100;
		var num21 = Math.random()*100;
		var num22 = Math.random()*100;
		var num23 = Math.random()*100;
		var num24 = Math.random()*100;
		//document.writeln(num);
		var g2=new GoogleChart();   
		g2.init('chart-01'); //Target Div ID    
		g2.setChartType('lc');   
		g2.setChartTitle('Line Chart Example');   
		g2.setChartSize('450x140');   
		g2.setChartColors('000066');   
		g2.setChartData([[num1,num2,num3,num4,num5,num6,num7,num8,num9,num10,num11,num12,num13,num14,num15,num16,num17,num18,num19,num20,num21,num22,num23,num24]]);   
		g2.setChartGrid('10,25,1,5');   
		g2.setLabels('');   
		g2.drawChart();
	},3000);
} 
</script>
</head>

<body>
<div id="chart-01"></div>
<div>实时刷新</div>
</body>
</html>
